/**
 * 指定年份日期
 */
import dayjs from "dayjs"

export const getFullYearDay = (n = 20, type = 'year'): [string, dayjs.Dayjs] => {
    let timestamp
    if (type === 'year') {
        timestamp = dayjs().add(n, 'year')
    } else {
        timestamp = dayjs().add(n, 'day')
    }
    return [timestamp.format('YYYY-MM-DD'), timestamp]
}